<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>注册</title>

    <style type="text/css">
        form
        {
            width:100%;
            height:100%;
            margin-top: 100px;
            margin-bottom: 100px;

        }
        .biaodan
        {
            display:inline-block;
            padding-top: 255px;
            padding-bottom: 255px;
            padding-left: 1px;
            padding-right: 1px;
        }
        
        #yonghuming
        {
            border-top: 6px solid rgb(0, 0, 0);
            border-right: 6px solid rgb(0, 0, 0);
            border-bottom-color: rgb(0, 0, 0);
            border-left-color: rgb(0, 0, 0);
            background-color: #4682B4;

        }

    </style>
    <link rel="stylesheet" href="layui-v2.6.8/layui/css/layui.css">
</head>
<body>
<ul class="layui-nav">
    <li class="layui-nav-item" ><a href="qiandao.html" style="font-size: 20px">我要签到</a></li>
    <li class="layui-nav-item" ><a href="out.html" style="font-size: 20px">我要离开</a></li>
    <li class="logo" style="float: right"><a href=""><img src="img/logo.png" width="60px" height="60px"></a></li>
    <li class="layui-nav-item" style="float: right" ><a href="zuche.html" style="font-size: 20px">我要注册</a></li>
    <li class="text_center" style="float: right;margin-right: 400px;line-height: 60px;color: gray;font-size: 30px" >智能软件研发实验室</li>
    <li class="layui-nav-item" ><a href="total.html" style="font-size: 20px">签到统计</a></li>
</ul>
<form>
    <center>
        <div class="biaodan">
            <h3 id="zhuce">
                注册
            </h3>
            <p >
                用户名：<input id="user" type="text" class="admin"/>
            </p>
            <p >
                学号：<input id="stuid" type="text" class="number"/>
            </p>
            <p>
                <input id="reg" type="submit" value="立即注册" />
            </p>

        </div>
    </center>
</form>
<div style="position: absolute;width: 100%;height: 100%;z-index: -1;left: 0;top: 0;">
    <img src="img/注册1111.jpg"/>
</div>

</body>
<script>
    $(function (){
    $("#reg").click(function (){
        var username = $("#user").val();
        var stuid = $("#stuid").val();
        $.ajax({
            url: "/regist",
            type: "get",
            data:{
                name:username,
                stuid:stuid
            },
            success: function (data) {
                if(date){
                    alert("注册成功")
                }else{
                    alert("注册失败")
                }
            },
        });
    })
</script>
</html>